﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;
using IHISCETeim.BLL;
using IHISCETeim.Library;
using IHISCETeim.Model;

namespace IHISCETeim.Web.MachineSys.PublicModel
{
    public partial class SPapersRemindAdd : PageBase
    {
        protected override Permission[] PowerKey
        {
            get
            {
                return new Permission[] { Permission.新增 };
            }
        }
        protected override string DWZRef
        {
            get { return "SPapersRemindList"; }
        }

        #region

        #endregion

        protected void Page_Load(object sender, EventArgs e)
        {
            if (GetRequestValue<string>("ajaxmethod", "") == "add")
            {
                addmenu();
            }
        }

        protected void addmenu()
        {
            SPapersRemindInfo obj2 = Request.SerializableObject<SPapersRemindInfo>();

            obj2.CreateUserId = User.UserId;
            //  obj2.AddRealName = User.RealName;

            this.AddLog(Permission.新增, "", obj2);

            if (SPapersRemindController.Add(obj2) > 0)
                SuccessJson("添加成功");
            else
                ErrorJson("添加失败");
        }
    }
}